package eu.dominicum.aas.pd.core;

import eu.dominicum.aas.pd.repo.TaskRepository;

import javax.inject.Inject;
import java.util.ArrayList;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.List;

public class Task extends AbstractDomainObject {

    @Inject
    private TaskRepository repo;

    private String description;
    private final Date created = new GregorianCalendar().getTime();
    private Date due;
    private Date started;
    private Date completed;
    private final List<Task> subtasks = new ArrayList<Task>();

    public String getDescription() {
        return description;
    }

    public Date getCreated() {
        return created;
    }

    public Date getDue() {
        return due;
    }

    public Date getStarted() {
        return started;
    }

    public Date getCompleted() {
        return completed;
    }

    public List<Task> getSubtasks() {
        return subtasks;
    }
}
